<%@ include file="/html/ccbs/portlet/hr_admin/init.jsp" %>

<%
	long merchantId = ParamUtil.getLong(request, "merchantId");
	MerchantEntry merchant = null;
	
	if (merchantId != 0) {
		merchant = MerchantEntryUtil.findByPrimaryKey(merchantId);
	}
	
	String[] mainSession = {"detail"};
	String[] actionSession = {""};
	
%>

<liferay-util:include page="/html/ccbs/portlet/hr_admin/toolbar.jsp" portletId="<%= portletDisplay.getId() %>">
	<liferay-util:param name="toolbarItem" value="add"/>
</liferay-util:include>

<liferay-util:header 
	backURL="<%= backURL %>"
	localizeTitle="<%= merchant == null%>"
	title='<%= merchant == null ? "add-new-merchant-entry" : merchant.getTitle() %>'
/>

<aui:form name="editMerchantForm" method="post" onSubmit='<%= "event.preventDefault();" + renderResponse.getNamespace() + "saveMerchant();" %>'>
	<aui:input name="<%= Constants.CMD %>" type="hidden"/>
	<aui:input name="redirect" type="hidden"/>
	
	<aui:model-context model="com.cmc.service.merchant.model.MerchantEntry" bean="<%= merchant%>"/>
	
	<aui:fieldset>
	
		
		
	</aui:fieldset>
	
	<div class="separator"></div>
	
	<aui:button-row>
		<aui:button type="submit"/>
	</aui:button-row>
	
</aui:form>

<%!
	private static String[] categoryNames = {"merchant-information", "merchant-actions"};
	private static Log _log = LogFactoryUtil.getLog("docroot.html.ccbs.portlet.hr_admin.edit_merchant_jsp");
%>